Demo Use Case (1) KST Basic FMIS
Scenario Flow
The following diagram illustrates the use case flow:
Prerequisite
Onboarding KST Basic FMIS (once): KST Basic FMIS operator should register KST Basic FMIS as a client at the KST Platform. Thus, the KST Platform operator should configure a public client for KST Basic FMIS. See CLIENT_MANAGEMENT.md.
First-Time Usage
A consent to authorize KST Basic FMIS to prosume (i.e., provide and consume) the farmer’s data via KST Platform should be established upon the first usage of KST Basic FMIS.
To use the features offered by KST Basic FMIS, the farmer has to connect it with their account on the KST Platform upon the first usage (i.e., the farmer should have an active consent for KST Basic FMIS on thier KST Platform account), as described in the following:
- The farmer signs in to KST-FIMS using their KST Platform account (OAuth 2.0 Authorization Code Flow):
- KST Basic FMIS redirects the farmer to the KST Platform.
- The farmer enters their KST Platform account credentials.
- KST Platform will redirect the user back to KST Basic FMIS.
- When using KST-FIMS for the first time, KST Basic FMIS prompts the farmer to configure the authorization level when connecting to their account on the KST Platform. The farmer can choose one of the following:
- Basic Access: With this level, the KST Basic FMIS can:
- Provide field data to the farmer’s account on the KST Platform.
- Consume field data from the farmer’s account on KST Platform.
- Full Access: With this level, the KST Basic FMIS can:
- Get Basic Access (see a).
- Provide disease report data to the farmer’s account on the KST Platform.
- Consume disease report data, and disease warnings data from the farmer’s account on KST Platform.
- Basic Access: With this level, the KST Basic FMIS can:
- KST Basic FMIS sends a consent request to the farmer’s account on KST Platform based on the selected level of authorization (in step 2).
- KST Basic FMIS redirects the farmer to the KST Platform.
- The farmer logs into their account on the KST Platform.
- The farmer (re)views the consent request details and accepts (or rejects) the request.
- KST Platform redirects the farmer to KST Basic FMIS where he/she can view the dashboard, and use its features based on the authorization level, if he/she has provided the consent in step 5 (otherwise they will be redirected to the KST Basic FMIS landing page).
KST Basic FMIS provides a feature that displays the current consent established with KST Platform and supports in revoking it. The farmer can view and revoke their consents at KST Platform as well. Once there is no active consent anymore, KST Basic FMIS can no longer provide or consume the data of that farmer and the farmer is treated as a first-time user of the service (step 2).
Subsequent Usage
- Sign in to KST Basic FIMS using your credentials on KST Platform (KST Basic FMIS redirects the user to the KST Platform, OAuth 2.0 Authorization Code Flow, where he/ she can enter their credentials, and then KST Platform would redirect the user back to KST Basic FMIS).
- The KST Basic FMIS consumes the required data from the farmer’s KST Platform account (based on the previously granted consent level).
- The farmer can continue using the features offered by KST Basic FMIS.